Skip to content

Conversation

@dtronmans
Copy link
Contributor

Purpose

Expand the parse and export suite with more classification formats that are accepted by FiftyOne. These include three new formats:

  • Flat collection of folders, each folder corresponding to a class name: before, classification_directory_parser was able to do this if these sub-folders were divided into train/valid/test/ subdirectories, now this works with a flat structure. The splits are generated at parse-time randomly.
  • train/validation/test subdirectories with a data folder and a labels.json residing in each
  • Flat structure: without the splitting of train/validation/test, just a flat structure with a data folder where the images reside and a labels.json file. Again the splits are randomly assigned

I did not have to implement the mechanism that randomly assigns splits for flat directory structure because this is handled by the LuxonisDataset make_splits() method which only assigns splits to unassigned ids. Here the default ratio is {"train": 0.8, "val": 0.1, "test": 0.1}

  • Implemented the corresponding ClassificationDirectoryExporter

Specification

Dependencies & Potential Impact

Deployment Plan

Testing & Validation

After parsing then exporting, then opening a session with the exported datasets:

MNIST:
mnist

Caltech101:
caltech101

Imagenet-sample:
imagenetsample

@dtronmans dtronmans requested a review from a team as a code owner January 6, 2026 16:05
@dtronmans dtronmans requested review from conorsim, klemen1999, kozlov721 and tersekmatija and removed request for a team January 6, 2026 16:05
@github-actions github-actions bot added the enhancement New feature or request label Jan 6, 2026
@klemen1999 klemen1999 requested a review from ptoupas January 7, 2026 09:24
Copy link
Collaborator

@klemen1999 klemen1999 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Structurally LGTM CC: @ptoupas if you could test out your usecase

Copy link

@ptoupas ptoupas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, tested it with imagenet-sample from fiftyone and works as expected.
One minor comment is to update the README respectively and add the new directory structure we support under the:
Classification Directory - A directory with subdirectories for each class bullet.

@github-actions github-actions bot added documentation Improvements or additions to documentation data Changes affecting luxonis_ml.data subpackage labels Jan 7, 2026
@dtronmans dtronmans merged commit 6fb9b0a into main Jan 7, 2026
13 checks passed
@dtronmans dtronmans deleted the feat/fiftyone-classification branch January 7, 2026 12:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

data Changes affecting luxonis_ml.data subpackage documentation Improvements or additions to documentation enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants